

import VueRouter from 'vue-router'

import Home from './components/homeContainer.vue'
import Member from './components/memberContainer.vue'
import Shop from './components/shoppingcarContainer.vue'
import Search from './components/searchContainer.vue'
import NewsList from './components/news/newsList.vue'
import NewsInfo from './components/news/newsInfo.vue'
import PhotoList from './components/photos/photoList.vue'
import PhotoInfo from './components/photos/photoInfo.vue'
import GoodsList from './components/goods/goodsList.vue'
import GoodsInfo from './components/goods/goodsInfo.vue'
import GoodsDesc from './components/goods/goodsDesc.vue'
import GoodsComment from './components/goods/goodsComment.vue'

var router = new VueRouter({
  routes: [
  { path: '/', redirect: '/home' },
  {path: '/home', component: Home},
  {path: '/member', component: Member},
  {path: '/shoppingcar', component: Shop},
  {path: '/search', component: Search},
  {path: '/home/newsList', component: NewsList},
  {path: '/home/newsinfo/:id', component: NewsInfo},
  {path: '/home/photoList', component: PhotoList},
  {path: '/home/photoInfo/:id', component: PhotoInfo},
  {path: '/home/goodsList', component: GoodsList},
  {path: '/home/goodsInfo/:id', component: GoodsInfo, name: 'goodsinfo'},
  {path: '/home/goodsDesc/:id', component: GoodsDesc, name: 'goodsdesc'},
  {path: '/home/goodsComment/:id', component: GoodsComment, name: 'goodscomment'},
  ],

  linkActiveClass: 'mui-active'
})

export default router